package com.sac.approval.domain;

import com.sac.approval.enums.ApprovalStatusEnum;
import com.sac.common.utils.DateUtils;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 
 * @author xiaodong
 * @email liu.xiaodong@hp.com
 * @date 2018-09-18 15:41:04
 */
@Data
public class ApprovalDO implements Serializable {
	private static final long serialVersionUID = 1L;
	
	//主键
	private String appId;
	//标题
	private String title;
	//内容
	private String content;
	//文本类型：0  plain 1 html 2 mhtml
	private String contType;
	//编码
	private String charSet;
	//保密类型: 0-常规，1-机密，2-最高机密
	private String secretType;
	//0-常规；1-紧急
	private String urgentType;
	//0- 1-全部
	private String notifyType;
	//审批状态：处理中...审批完成
	private Integer status;
	//创建人
	private String createUser;
	//创建时间
	private Date createTime;

	private String createUserNm;

	private String createUserJob;

	private String completeNum;

	private List<AttachmentDO> attachmentList;

	private String statusName;

	private String createTimeString;

	private String pendingApprover;

	private String category;

	private String appLineId;


	public String getStatusName() {
		return ApprovalStatusEnum.getStatusEnumByValue(this.status).getName();
	}

	public String getCreateTimeString() {
		return DateUtils.format(this.createTime,"MM-dd hh:mm");
	}
	
}
